﻿using System;
namespace Microsoft.Data.OData.Query
{
    /// <summary>
    /// Public enumeration of kinds of query nodes. A subset of InternalQueryNodeKind
    /// </summary>
    public enum QueryNodeKind
    {
        /// <summary>
        /// No query node kind...  the default value.
        /// </summary>
        None,
        /// <summary>
        /// A constant value.
        /// </summary>
        Constant,
        /// <summary>
        /// A node that represents conversion from one type to another.
        /// </summary>
        Convert,
        /// <summary>
        /// Non-entity node referencing a range variable.
        /// </summary>
        NonentityRangeVariableReference,
        /// <summary>
        /// Node used to represent a binary operator.
        /// </summary>
        BinaryOperator,
        /// <summary>
        /// Node used to represent a unary operator.
        /// </summary>
        UnaryOperator,
        /// <summary>
        /// Node describing access to a property which is a single (non-collection) non-entity value.
        /// </summary>
        SingleValuePropertyAccess,
        /// <summary>
        /// Node describing access to a property which is a non-entity collection value.
        /// </summary>
        CollectionPropertyAccess,
        /// <summary>
        /// Function call returning a single value.
        /// </summary>
        SingleValueFunctionCall,
        /// <summary>
        /// Any query.
        /// </summary>
        Any,
        /// <summary>
        /// Node for a navigation property with target multiplicity Many.
        /// </summary>
        CollectionNavigationNode,
        /// <summary>
        /// Node for a navigation property with target multiplicity ZeroOrOne or One.
        /// </summary>
        SingleNavigationNode,
        /// <summary>
        /// Single-value property access that refers to an open property.
        /// </summary>
        SingleValueOpenPropertyAccess,
        /// <summary>
        /// Cast on a single thing.
        /// </summary>
        SingleEntityCast,
        /// <summary>
        /// All query.
        /// </summary>
        All,
        /// <summary>
        /// Cast on a collection of entities.
        /// </summary>
        EntityCollectionCast,
        /// <summary>
        /// Placeholder node referencing a rangeVariable on the binding stack that references an entity.
        /// </summary>
        EntityRangeVariableReference,
        /// <summary>
        /// Node the represents a function call that returns a single entity.
        /// </summary>
        SingleEntityFunctionCall,
        /// <summary>
        /// Node that represents a function call that returns a collection.
        /// </summary>
        CollectionFunctionCall,
        /// <summary>
        /// Node that represents a funciton call that returns a collection of entities.
        /// </summary>
        EntityCollectionFunctionCall,
        /// <summary>
        /// Node that represents a named function parameter. 
        /// </summary>
        NamedFunctionParameter
    }
}
